#include "../../source/server.hpp"

int main()
{
    Socket cli_sock;
    cli_sock.CreateClient(8500,"127.0.0.1");
    for(int i = 0; i < 5; i++)
    {
        std::string str = "hello!!!";
        cli_sock.Send(str.c_str(),str.size());
        char buffer[1024] = {0};
        cli_sock.Recv(buffer,sizeof(buffer) - 1);
        logMessage(DEBUG,"client send one message:%s",buffer);
        sleep(1);
    }
    int i = 0;
    while(1) 
    {
        logMessage(DEBUG,"[%d]There are currently no new connections",i++);
       sleep(1); 
       if(i == 11)
            break;
    }
    return 0;
}

